import { defineStore } from 'pinia'

//本地存储对象
export const appStore = defineStore({
    id: "appStore",
    state: () => {
        return {
            userId: 0,//用户id
            phone: ""//手机号
        }
    },
    getters: {},
    actions: {},
    //开启数据持久化
    persist: {
        enabled: true,
        strategies: [
            {
                key: 'jjx-app',
                storage: localStorage,
            }
        ]
    }
})